//
//  UserAccount.swift
//  YYWeiBo
//
//  Created by 崔洋洋 on 15/10/10.
//  Copyright © 2015年 崔洋洋. All rights reserved.
//

import UIKit

// 用户模型
class UserAccount: NSObject {

    // 用于调用access_token，接口获取授权后的access token
    var access_token: String?
    
    // access_token的生命周期，单位是秒数 - 准确的数据是一个数值
    var expires_in: NSTimeInterval = 0
    
    // 当前授权用户的UID
    var uid: String?
    
    init(dict: [String: AnyObject]) {
        super.init()
        
        setValuesForKeysWithDictionary(dict)
        
    }
    override func setValue(value: AnyObject?, forUndefinedKey key: String) {
        var description: String {
            let properties = ["access_token","expires_in","uid"]
            return "\(dictionaryWithValuesForKeys(properties))"
        }
    }
}
